import request from '@/utils/request'
//试卷列表
export function fetchExamList(data) {
  return request({
    url: '/api/v1//exams/getAll',
    method: 'post',
    data: data
  })
}
//试卷详情
export function getExamDetail(id) {
  return request({
    url: '/api/v1/exams/detail/'+id,
    method: 'post'
  })
}
//新增或编辑试卷
export function saveExam(data){
  return request({
      url: '/api/v1/exams/add',
      method: 'post',
      data: data
  })
}
//删除试卷
export function deleteExam(id){
  return request({
      url: '/api/v1/exams/delete/'+id,
      method: 'post'
  })
}
//发布试卷
export function publishExam(id){
    return request({
      url: '/api/v1/exams/publish/'+id,
      method: 'post'
  })
}







